#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Time     : 2021/3/19 11:06 上午
# @Author   : xiaoyang
# @Email    :296559739@qq.com
# @File     : yangzhen0301.py
class pip:
    #类构造实例方法
    def __init__(self):
        self.name = 'python提莫班'
        self.add = 'http://39.105.34.24:7000/'
    def say(self):
        print('调用say()实例方法')
A = pip()
A.say()

class pip_1:
    def __init__(self):
        self.name = 'python提莫班'
        self.add = 'http://39.105.34.24:7000/'
    @classmethod
    def info(cls):
        print('正在调用类方法')
#使用类名直接调用
pip_1.info()

class pip_2:
    @staticmethod
    def info_1(name,add):
        print(name,add)
#使用类名直接调用静态方法
pip_2.info_1('提莫班','第一期')
#使用类对象调用静态方法
B = pip_2()
B.info_1('提莫班','第一期')